// Fill out your copyright notice in the Description page of Project Settings.

#pragma once

#include "CoreMinimal.h"
#include "Factories/Factory.h"
#include "AssetTypeCategories.h"
#include "Blueprint/WidgetTree.h"
#include "LuaWidgetFactory.generated.h"

/**
 * 
 */
class UWidgetTree;
UCLASS()
class SGAMEEDITOR_API ULuaWidgetFactory : public UFactory
{
	GENERATED_BODY()
public:
	ULuaWidgetFactory(const FObjectInitializer& InObject);

	/** Returns the name of the factory for menus */
	virtual FText GetDisplayName() const override { return FText::FromString("Lua Widget"); }

	/** When shown in menus, this is the category containing this factory. Return type is a BitFlag mask using EAssetTypeCategories. */
	virtual uint32 GetMenuCategories() const override { return EAssetTypeCategories::UI; }

	/** Returns the tooltip text description of this factory */
	virtual FText GetToolTip() const override { return FText::FromString("Create user widget supports Lua"); }

protected:
	virtual UObject* FactoryCreateNew(UClass* InClass, UObject* InParent, FName InName, EObjectFlags Flags, UObject* Context, FFeedbackContext* Warn) override;
	
};
